package com.fpf.lab01_basics;

public class Demo2_RunnableLambda {
    public static void main(String[] args) {
//        new Thread(new Runnable() {
//            @Override
//            public void run() {
//                System.out.println("Lambda running " + Thread.currentThread().getName());
//            }
//        }).start(); java8之前的写法

        // lambda + runnable
        new Thread(()-> System.out.println("Lambda running "+Thread.currentThread().getName())).start();
    }
}
